package com.daisuxia.web.pojo;

public class BackConfigParams {
	/** configParams表中邮箱的sys_type */
	public static final String SMTP = "SMTP";
	/** configParams表中短信的sys_type */
	public static final String SMS = "SMS";
	/** configParams表中短信验证各种限制的的sys_type */
	public static final String SMSCODE = "SMSCODE";
	/** configParams表中网站参数的sys_type */
	public static final String WEBSITE = "WEBSITE";
	/** configParams表中关于我们的sys_type */
	public static final String CHANNEL = "CHANNEL";
	/** configParams表中芝麻信用的sys_type */
	public static final String ZMXY = "ZMXY";
	/** configParams表中聚信立的sys_type */
	public static final String JXL = "JXL";
	/** configParams表中服务费账户的sys_type */
	public static final String FEE_ACCOUNT = "FEE_ACCOUNT";
	/** configParams表中同盾的sys_type */
	public static final String TD = "TD";
	/** configParams表中白骑士的sys_type */
	public static final String BQS = "BQS";
	/** configParams表中算话的sys_type */
	public static final String SH = "SH";
	/** configParams表中白骑士的sys_type */
	public static final String JYZX = "JYZX";
	/** configParams表中爬虫规则的费率 */
	public static final String SYS_FEE = "SYS_FEE";
	/** configParams表中富友的配置 */
	public static final String FUYOU = "FUYOU";
	/** configParams表中连连的配置 */
	public static final String LIANLIAN = "LIANLIAN";
	/** configParams表中银生的配置 */
	public static final String YINSHENG = "YINSHENG";
	/** configParams表中催收的配置 */
	public static final String COLLECTION = "COLLECTION";
	/** configParams表中宜信的费率 */
	public static final String YX = "YX";
	/** configParams表中APP_URL */
	public static final String APP_IMG_URL = "APP_IMG_URL";
	/** 二次调用接口需要间隔的时间 */
	public static final String INTERVAL = "INTERVAL";
	/** 中智诚请求 */
	public static final String ZZC = "ZZC";
	/** 中智诚风险名单 */
	public static final String ZZC_BLACK = "ZZC_BLACK";
	/**系统级，不可页面编辑，仅能后台配置项*/
	public static final String SYSTEM = "SYSTEM";
	/**闪银推送的systype*/
	public static final String SY_TS = "SY_TS";
	/**魔蝎的sys_type*/
	public static final String MX = "MX";
	/** configParams表中米到啦P2P和现金贷交互的系统参数sys_type */
	public static final String YANGYUE_MDL_API = "YANGYUE_MDL_API";
	/**************_client_配置参数*****************/
	public static final String MDL_SYS_CLIENT = "MDL_SYS_CLIENT";
	/**************key米到啦系统参数*****************/
	public static final String MDL_SYS_KEY = "MDL_SYS_KEY";
	/**************_DEVICEID_米到啦*****************/
	public static final String MDL_SYS_DEVICEID = "MDL_SYS_DEVICEID";
	/**************通知P2P打包放款接口*****************/
	public static final String MDL_LOAN_NOTIFY = "MDL_LOAN_NOTIFY";
	/**************P2P结束订单地址URL*****************/
	public static final String MDL_FINISH_ORDER_URL = "MDL_FINISH_ORDER_URL";
	/**************轮询查询P2P平台放款状态*****************/
	public static final String MDL_LOAN_PACKAGE_STATUS = "MDL_LOAN_PACKAGE_STATUS";
	/**************单笔通知P2P发起代扣业务*****************/
	public static final String MDL_LOAN_PAYMENT = "MDL_LOAN_PAYMENT";
	/**************是否调用P2P接口开关*****************/
	public static final String MDL_API_ISOPEN = "MDL_API_ISOPEN";
	/**************是否打开短连接渠道接口开关*****************/
	public static final String SHORT_SMS_OPEN = "SHORT_SMS_OPEN";
	/*聚信立报告查询开关*/
	public static final String JXL_REPORT_OPEN = "JXL_REPORT_OPEN";
	
	/**************是否调用P2P资产包大小*****************/
	public static final String MDL_ASSET_SIZE = "MDL_ASSET_SIZE";
	/**************P2P请求地址URL*****************/
	public static final String MDL_POST_URL = "MDL_POST_URL";
	
	
	
	public static final String YSPAY_SUCCESS_CODE = "0000";
	
	static {
	}

	public enum inputTypeEnum {
		text, textarea, password, image;
	}

	private Integer id;

	private String sysName;

	private String sysValue;

	private String sysValueBig;
	private String sysValueView;

	public String getSysValueView() {
		return sysValueView;
	}

	public void setSysValueView(String sysValueView) {
		this.sysValueView = sysValueView;
	}

	private String sysKey;

	private String sysType;

	private String inputType;

	private String remark;

	private String limitCode;

	public Integer getId() {
		return id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	public String getSysName() {
		return sysName;
	}

	public void setSysName(String sysName) {
		this.sysName = sysName == null ? null : sysName.trim();
	}

	public String getSysValue() {
		return sysValue;
	}

	public void setSysValue(String sysValue) {
		this.sysValue = sysValue == null ? null : sysValue.trim();
	}

	public String getSysKey() {
		return sysKey;
	}

	public void setSysKey(String sysKey) {
		this.sysKey = sysKey == null ? null : sysKey.trim();
	}

	public String getSysType() {
		return sysType;
	}

	public void setSysType(String sysType) {
		this.sysType = sysType == null ? null : sysType.trim();
	}

	public String getRemark() {
		return remark;
	}

	public void setRemark(String remark) {
		this.remark = remark == null ? null : remark.trim();
	}

	public String getLimitCode() {
		return limitCode;
	}

	public void setLimitCode(String limitCode) {
		this.limitCode = limitCode == null ? null : limitCode.trim();
	}

	public String getSysValueBig() {
		return sysValueBig;
	}

	public void setSysValueBig(String sysValueBig) {
		this.sysValueBig = sysValueBig == null ? null : sysValueBig.trim();
	}

	public String getInputType() {
		return inputType;
	}

	public void setInputType(String inputType) {
		this.inputType = inputType;
	}

	/**
	 * 自动匹配，不用关心类型 但是InputType必须有值
	 * 
	 * @param value
	 */
	public void setSysValueAuto(String value) {

		if (inputTypeEnum.textarea.name().equals(this.getInputType())) {
			this.setSysValueBig(value);
		} else if (inputTypeEnum.text.name().equals(this.getInputType())) {
			this.setSysValue(value);
		} else if (inputTypeEnum.password.name().equals(this.getInputType())) {
			this.setSysValue(value);
		} else if (inputTypeEnum.image.name().equals(this.getInputType())) {
			this.setSysValue(value);
		}
	}

	/**
	 * 自动匹配，不用关心类型 但是InputType必须有值
	 * 
	 * @param value
	 */
	public String getSysValueAuto() {
		String sysValueAuto = null;
		if (inputTypeEnum.textarea.name().equals(this.getInputType())) {
			sysValueAuto = this.getSysValueBig();
		} else if (inputTypeEnum.text.name().equals(this.getInputType())) {
			sysValueAuto = this.getSysValue();
		} else if (inputTypeEnum.password.name().equals(this.getInputType())) {
			sysValueAuto = this.getSysValue();
		} else if (inputTypeEnum.image.name().equals(this.getInputType())) {
			sysValueAuto = this.getSysValue();
		}
		return sysValueAuto;
	}

	@Override
	public String toString() {
		return "BackConfigParams [id=" + id + ", inputType=" + inputType + ", limitCode=" + limitCode + ", remark=" + remark + ", sysKey=" + sysKey
				+ ", sysName=" + sysName + ", sysType=" + sysType + ", sysValue=" + sysValue + ", sysValueBig=" + sysValueBig + ", sysValueView="
				+ sysValueView + "]";
	}

}